const API = require('../../pages/api/index')
const { typeJson } = require('../../utils/typejson')
let prolist = wx.getStorageSync('prolist')==''?wx.getStorageSync('prolist'):JSON.parse(wx.getStorageSync('prolist'))


Page({

  /**
   * 页面的初始数据
   */
  data: {
    pulldown:"",
    pullup:2,
    addButton:true,
    prolist:wx.getStorageSync('prolist')==''?wx.getStorageSync('prolist'):JSON.parse(wx.getStorageSync('prolist')),
    listConfig: [
      {
        prop: "administer",
        label: "上传人",
       
    },
    {
      prop: "updateTime",
      label: "更新时间",
    },
      ],

      formConfig: [
        {
          prop: "administer",
          label: "上传人",
      },
      {
        prop: "remark",
        label: "说明",
    },
      {
        prop: "updateTime",
        label: "更新时间",
        type:"dateTime"
      },
      
        {
          label: '附件',
          prop: 'fileUrl',
          type: 'image'
        },


     
       
      
        ],
    
        
        net: {
       
            select: {
              url: `/app/fourColorImage/getList`,
              method: 'post',
              data: {
                mineId: true,
                
              }
            },
            delete: {
              url: '/app/fourColorImage/delete',
              method: 'post',
              data: {
                
              }
            },
            insert: {
              url: '/app/fourColorImage/insert',
              method: 'post',
              data: {
                mineId:true,
              
               
              }
            },
            update: {
              url: '/app/fourColorImage/update',
              method: 'post',
              data: {
  
              }
            }
  
          
        },
        showCom:true
      },

     
  

  /**
   * 生命周期函数--监听页面加载
   */


  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {

  },
  
  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {
    console.log('5555');
    this.setData({
      showCom: false
    });
    this.setData({
      showCom: true
    });
  },

  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {

  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {

  },

   /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {
    wx.stopPullDownRefresh()
  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {
    this.setData({
      pullup: this.data.pullup + 1
    })
  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {

  }
})